<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:zj="http://www.zju.edu.cn" xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="zj msxsl">
  <xsl:import href="../Tk2Template/DetailTemplate.xslt"/>
  <xsl:import href="TreeDetailTemplate_Trans.xslt"/>
  <xsl:output method="html" indent="no"/>
  <xsl:variable name="zj:TableDesc" select="$zj:XmlData/Toolkit/zj:Table/@TableDesc"/>
  <xsl:variable name="TableCount" select="count($zj:XmlData/Toolkit/zj:Table)"/>
  <xsl:template match="/">    
    <div class="easyui-layout" fit="true">
      <xsl:choose>
        <xsl:when test="$TableCount > 1">
          <div region="north" split="true" style="height:250px;" name="ss" title='{$zj:TableDesc}' >
            <xsl:call-template name="zj:Content"/>
            <div class="p-right">
              <xsl:call-template name="zj:Button"/>
            </div>
          </div>
          <div region="center" style="padding:5px;">
            <xsl:call-template name="zj:DetailList"/>
          </div>
        </xsl:when>
        <xsl:otherwise>
          <div region="center" style="padding:5px;">
            <xsl:call-template name="zj:Content"/>
            <div class="p-right">
              <xsl:call-template name="zj:Button"/>
            </div>
          </div>
        </xsl:otherwise>
      </xsl:choose>     
    </div>
  </xsl:template>
</xsl:stylesheet>
